package com.didd.core.common.base;

import lombok.Data;
import lombok.EqualsAndHashCode;
import lombok.NoArgsConstructor;

import javax.validation.constraints.NotBlank;
import javax.validation.constraints.Size;

/**
 * 所有请求的基类
 *
 * @author diddd
 * @date 2019/07/18
 */
@Data
@NoArgsConstructor
@EqualsAndHashCode(callSuper = false)
public class DomainAndModuleCodeRequest extends BaseRequest {

    /**
     * 主键id
     */
    @NotBlank(message = "域编码不能为空")
    protected String domainCode;

    /**
     * 模块编码
     */
    @Size(max = 16)
    @NotBlank(message = "模块编码不能为空")
    private String moduleCode;

    public DomainAndModuleCodeRequest(String domainCode,String moduleCode) {
        this.domainCode = domainCode;
        this.moduleCode = moduleCode;
    }


}
